package com.example.service;

import com.example.mapper.PersonMapper;
import com.example.pojo.Person;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author およそ神
 * @version JDK 1.8
 */
@Service
public class PersonServiceImpl implements PersonService{
    @Autowired
    PersonMapper personMapper;
    @Override
    public Boolean addPerson(Person person) {
        return personMapper.addPerson(person);
    }

    @Override
    public Person searchById(Integer id) {
        return personMapper.searchById(id);
    }

    @Override
    public List<Person> searchAll() {
        return personMapper.searchAll();
    }
}
